<div class="form">

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'gn-members-form',
	'enableAjaxValidation'=>false,
)); ?>

	<p class="note">Fields with <span class="required">*</span> are required.</p>

	<?php echo $form->errorSummary($model); ?>

    <table border="0">
    <tr>
      <td width="1">
        <div class="row">
            <?php echo $form->labelEx($model,'Sponsor ID'); ?>
            <?php echo $form->textField($model,'parent_id'); ?>
            <?php echo $form->error($model,'parent_id'); ?>
        </div>
      </td>
      <td width="1">
        <div class="row">
            <?php echo $form->labelEx($model,'Position'); ?>
            <?php echo $form->textField($model,'position',array('size'=>15,'maxlength'=>15)); ?>
            <?php echo $form->error($model,'position'); ?>
        </div>
      </td>
      <td>
        <div class="row">
            <?php echo $form->labelEx($model,'Level'); ?>
            <?php echo $form->textField($model,'level',array('size'=>8,'maxlength'=>8)); ?>
            <?php echo $form->error($model,'level'); ?>
        </div>
      </td>
    </tr>
    </table>
      
    <hr />
    
    
	<div class="row">
        <table border="0">
        <tr>
          <td>
			<?php echo $form->labelEx($model,'First Name'); ?>
            <?php echo $form->textField($model,'f_name',array('size'=>25,'maxlength'=>25)); ?>
            <?php echo $form->error($model,'f_name'); ?>
          </td>
          <td>  
            <?php echo $form->labelEx($model,'Last Name'); ?>
            <?php echo $form->textField($model,'l_name',array('size'=>25,'maxlength'=>25)); ?>
            <?php echo $form->error($model,'l_name'); ?>
          </td>
          <td>  
            <?php echo $form->labelEx($model,'Middle Name'); ?>
            <?php echo $form->textField($model,'m_initial',array('size'=>25,'maxlength'=>25)); ?>
            <?php echo $form->error($model,'m_initial'); ?>
          </td>
        </tr>
        </table>
	</div>
    
    <hr />
    
	<div class="row">
        <table border="0">
        <tr>
          <td>
			<?php echo $form->labelEx($model,'Email'); ?>
            <?php echo $form->textField($model,'email',array('size'=>40,'maxlength'=>40)); ?>
            <?php echo $form->error($model,'email'); ?>
          </td>
          <td>
            <?php echo $form->labelEx($model,'Mobile_no'); ?>
			<?php echo $form->textField($model,'mobile_no',array('size'=>40,'maxlength'=>40)); ?>
            <?php echo $form->error($model,'mobile_no'); ?>
          </td>
        </tr>
        <tr>
          <td>
            <?php echo $form->labelEx($model,'Tax Identification No (TIN)'); ?>
			<?php echo $form->textField($model,'tin',array('size'=>40,'maxlength'=>40)); ?>
            <?php echo $form->error($model,'tin'); ?>
          </td>
          <td> 
            <?php echo $form->labelEx($model,'Birthday'); ?>
            <?php echo $form->textField($model,'birthday'); ?>
            <?php echo $form->error($model,'birthday'); ?>
          </td>
        </tr>
        </table>
	</div>
 
    <hr />
   
	<div class="row">
        <table>
          <tr>
            <td>
              <div class="row">
				<?php echo $form->labelEx($model,'Main Address'); ?>
                <?php echo $form->textField($model,'address_1',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'address_1'); ?>
              </div>
              <div class="row">  
                <?php echo $form->labelEx($model,'Main Region'); ?>
                <?php echo $form->textField($model,'region_1',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'region_1'); ?>
              </div>
              <div class="row">
                <?php echo $form->labelEx($model,'Main Province'); ?>
                <?php echo $form->textField($model,'province_1',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'province_1'); ?>
              </div>
              <div class="row">
                <?php echo $form->labelEx($model,'Main Country'); ?>
                <?php echo $form->textField($model,'country_1',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'country_1'); ?>
              </div>
            </td>
            <td>
              <div class="row">
				<?php echo $form->labelEx($model,'Secondary Address'); ?>
                <?php echo $form->textField($model,'address_2',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'address_2'); ?>
              </div>
              <div class="row">
                <?php echo $form->labelEx($model,'Secondary Region'); ?>
                <?php echo $form->textField($model,'region_2',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'region_2'); ?>
              </div>
              <div class="row">
                <?php echo $form->labelEx($model,'Secondary Province'); ?>
                <?php echo $form->textField($model,'province_2',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'province_2'); ?>
              </div>
              <div class="row">
                <?php echo $form->labelEx($model,'Secondary Country'); ?>
                <?php echo $form->textField($model,'country_2',array('size'=>45,'maxlength'=>45)); ?>
                <?php echo $form->error($model,'country_2'); ?>
              </div>
            
            </td>
          </tr>
        </table>
    </div>
    
    <hr />
	
    <table border="0">
    <tr>
      <td>      
        <div class="row">
            <?php echo $form->labelEx($model,'Business Name'); ?>
            <?php echo $form->textField($model,'business_entity',array('size'=>45,'maxlength'=>45)); ?>
            <?php echo $form->error($model,'business_entity'); ?>
        </div>
        <div class="row">
			<?php echo $form->labelEx($model,'Business Type'); ?>
            <?php echo $form->textField($model,'business_type',array('size'=>45,'maxlength'=>45)); ?>
            <?php echo $form->error($model,'business_type'); ?>
        </div>
      </td>
      <td>          
        <div class="row">
            <?php echo $form->labelEx($model,'Business Address'); ?>
            <?php echo $form->textField($model,'business_addr',array('size'=>45,'maxlength'=>45)); ?>
            <?php echo $form->error($model,'business_addr'); ?>
        </div>
    
        <div class="row">
            <?php echo $form->labelEx($model,'business_region'); ?>
            <?php echo $form->textField($model,'business_region',array('size'=>45,'maxlength'=>45)); ?>
            <?php echo $form->error($model,'business_region'); ?>
        </div>
    
        <div class="row">
            <?php echo $form->labelEx($model,'business_province'); ?>
            <?php echo $form->textField($model,'business_province',array('size'=>45,'maxlength'=>45)); ?>
            <?php echo $form->error($model,'business_province'); ?>
        </div>
    
        <div class="row">
            <?php echo $form->labelEx($model,'Business Country'); ?>
            <?php echo $form->textField($model,'business_country',array('size'=>45,'maxlength'=>45)); ?>
            <?php echo $form->error($model,'business_country'); ?>
        </div>
     </td>
   </tr>  
   </table>	
 
    <hr />

    
    <table border="0">
    <tr>
      <td>
        <div class="row">
            <table border="0">
            <tr>
              <td width="1">
                 <?php echo $form->checkBox($model,'auto_renew'); ?>
              </td>
              <td>
                 <?php echo $form->labelEx($model,'Auto Renew Membership'); ?>
              </td>
            </tr>
            </table>
            <?php echo $form->error($model,'auto_renew'); ?>
        </div>
      </td>
      <td>
        <div class="row">
            <table border="0">
            <tr>
              <td width="1">
                <?php echo $form->checkBox($model,'auto_order'); ?> 
			  </td>
              <td> 
			     <?php echo $form->labelEx($model,'Auto Order'); ?>
              </td>
            </tr>
            </table>
            <?php echo $form->error($model,'auto_order'); ?>
        </div>
      </td>
      <td>
        <div class="row">
            <?php echo $form->labelEx($model,'dt_joined'); ?>
            <?php echo $form->textField($model,'dt_joined'); ?>
            <?php echo $form->error($model,'dt_joined'); ?>
        </div>
      </td>
    </tr>
    </table>
	

	
    <!--
	<div class="row">
		<?php echo $form->labelEx($model,'Left Dealer'); ?>
		<?php echo $form->textField($model,'l_node'); ?>
		<?php echo $form->error($model,'l_node'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'Right Dealer'); ?>
		<?php echo $form->textField($model,'r_node'); ?>
		<?php echo $form->error($model,'r_node'); ?>
	</div>
    -->

    <!--
	<div class="row">
		<?php echo $form->labelEx($model,'dt_created'); ?>
		<?php echo $form->textField($model,'dt_created'); ?>
		<?php echo $form->error($model,'dt_created'); ?>
	</div>
    -->
    
	<div class="row buttons" align="center">
		<?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
	</div>

<?php $this->endWidget(); ?>

</div><!-- form -->